package it.koutifaris.travianmap.db;

import android.provider.BaseColumns;

/**
 * Taken from google Note Pad example:<br/>
 * 
 * Defines a contract between the TravianMap content provider and its clients. A contract defines the information that a
 * client needs to access the provider as one or more data tables. A contract is a public, non-extendable (final) class
 * that contains constants defining column names and URIs. A well-written client depends only on the constants in the
 * contract.
 * 
 * @author Kouty
 * 
 */
public final class TMapDomain {
	public static final String AUTHORITY = "it.kouty.provider.TravianMap";

	private TMapDomain() {
	}

	public static final class Villages implements BaseColumns, Auditable {

		public static final String TABLE_NAME = "villages";

		public static final String COLUMN_NAME_X = "x";
		public static final String COLUMN_NAME_Y = "y";
		public static final String COLUMN_NAME_VILLAGE_ID = "villageId";
		public static final String COLUMN_NAME_VILLAGE_NAME = "name";
		public static final String COLUMN_NAME_POPULATION = "population";
		public static final String COLUMN_NAME_OWNER_ID = "ownerId";

		private Villages() {
		}
	}

	public static final class Players implements BaseColumns, Auditable {

		public static final String TABLE_NAME = "players";
		public static final String COLUMN_NAME_PLAYER_ID = "playerId";
		public static final String COLUMN_NAME_PLAYER_NAME = "name";
		public static final String COLUMN_NAME_TRIBE = "tribe";
		public static final String COLUMN_NAME_ALLIANCE_ID = "allianceId";

		private Players() {
		}
	}

	public static final class Alliances implements BaseColumns, Auditable {

		public static final String TABLE_NAME = "players";
		public static final String COLUMN_NAME_ALLIANCE_ID = "allianceId";
		public static final String COLUMN_NAME_ALLIANCE_NAME = "name";

		private Alliances() {
		}
	}

	public static final class Revisions implements BaseColumns {

		public static final String TABLE_NAME = "revisions";
		public static final String COLUMN_NAME_REVISION_ID = "revisionId";
		public static final String COLUMN_NAME_DATE = "date";

		private Revisions() {
		}
	}
}
